/*
 * BrokenStep.h
 *
 *  Created on: Dec 14, 2011
 *      Author: jianli
 */

#ifndef UNREGULAR_SPRITE_H_
#define UNREGULAR_SPRITE_H_

#include "multiSprite.h"

class UnregularSprite: public MultiSprite {
public:
	UnregularSprite(const Vector2f& pos, const Vector2f& vel, const Frame* fm,
			const string& name) :
			MultiSprite(pos, vel, fm, name),
			collided(false) {
	}
	virtual ~UnregularSprite() {};

	virtual const Frame* getFrame() const;
	virtual void draw() const;
	virtual void update(Uint32 ticks);
	virtual bool collide(Sprite*);

protected:
	bool collided;
	virtual void advanceFrame(Uint32 ticks);
};

#endif /* BROKENSTEP_H_ */
